package com.yaoxuguang.concurrence.simpleDataFormate_thread_question;

import java.text.SimpleDateFormat;

/**
 * @author yaoxuguang
 * @Title: yao-interview
 * @Package com.yaoxuguang.concurrence.simpleDataFormate_thread_question
 * @Description: 测试SimpleDateFormat并发问题
 * @date 2018年12月26日14:24
 */
public class Test {
    public static void main(String[] args) {
        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
        String [] dateString = new String[]{
                "2000-01-01","2000-01-02","2000-01-03","2000-01-04","2000-01-05",
                "2000-01-06","2000-01-07","2000-01-08","2000-01-09","2000-01-10"
        };
        MyThread [] myThreads = new MyThread[10];
        for (int i = 0; i < 10; i++) {
            myThreads[i] = new MyThread(simpleDateFormat,dateString[i]);
        }
        for (int i = 0; i < 10; i++) {
            myThreads[i].start();
        }
    }
}
